package com.jiashihui.schema_lgorithm.schema.strategy;

/**
 * @author jiashihui
 * @describe: 抽象的计算器类
 * @date 2019/03/14
 */
public abstract class AbstractCalculator {

    /**
     * 处理参数
     *
     * @author jiashihui
     * @param exp
     * @param opt
     */
    public int[] split(String exp, String opt) {
        String array[] = exp.split(opt);
        int arrayInt[] = new int[2];
        arrayInt[0] = Integer.parseInt(array[0]);
        arrayInt[1] = Integer.parseInt(array[1]);
        return arrayInt;
    }

}
